package exteditapp.state;

import exteditapp.AppletIterator;
import exteditapp.FileDefault;
import exteditapp.action.ActionEditingDone;
import exteditapp.command.CommandUpload;

/**
 * State - edit (shows when was last modification)
 * @author Arturas Smorgn, arturas@smorgun.lt
 */
public class StateEditingDone extends StateUploading {

	/**
	 * Default constructor
	 * @param iterator is system iterator, which performs all actions
	 * @param file this is file, which state we will hold
	 */
	public StateEditingDone(AppletIterator iterator, FileDefault file) {
		super(iterator, file);
		start();
	}
	public StateEditingDone(AppletIterator iterator, FileDefault file, boolean doRegister){
		super(iterator, file, doRegister);
		start();
	}
	
	protected void start(){
		this.setAction(new ActionEditingDone());
		this.file.getModule().getInvoker().execute(new CommandUpload(this.file));
	}
	
	/**
	 * Handling of new state
	 */
	public boolean handle() {
		//TODO implement edit state handling
		return false;
	}
	
}
